<?php
echo $form->create('Status', array('action' => 'add','data-ajax' => 'false'));
?>
<?php if( $datahash['login_user']['User']['campus_id'] != 0 ){ ?>
<div data-role="fieldcontain">
<?php
echo $form->label('text','カテゴリ:',array('for' => 'text'));
echo $form->select('category_id', $datahash['category'], null, array('empty' => false));
?>
</div>
<?php } ?>

<div data-role="fieldcontain">
<?php
if(isset($_GET['quote'])){
	$insertText = 'RT @'.$_GET['to'].': '.unescape($_GET['quote']);
} else {
	$insertText = '@'.$_GET['to'].' ';
}
echo $form->input('text',array('maxLength' => 134,'placeholder' => "134字以内で入力", 'id' => 'reply_tweet', 'value'=> $insertText ,'label' => false, 'div' => false));
?>
</div>
<?php echo $form->hidden('user_id',array('value' => $datahash['login_user']['User']['id']));?>
<?php if($_GET['lat'] != null){ ?>
<?php echo $form->hidden('lat',array('value' => $_GET['lat']));?>
<?php echo $form->hidden('lng',array('value' => $_GET['lng']));?>
<?php } ?>
<div data-role="fieldcontain">
<?php
echo $form->submit('送信');
?>
</div>
<?php
echo $form->end();
?>